package squares;
/**
 * An exception class that is thrown when the given TemperatureType is not valid (not celsius, kelvin nor farenheit)
 * It returns an error message
 * 
 * @version 1
 * @author 	Gilles Groven & Jochen Tombal
 */
public class IllegalTemperatureTypeException extends Exception {
	
	/**
	 *  A version number for classes that implement the interface
	 * Serializable which is strongly recommends by Java API
	 */
	private static final long serialVersionUID = 97612014752813143L;
	/**
	 *  The error message that is to be returned, expressed as a string.
	 *  This message gives the user more information about origin of the error.
	 */
	private final String message;
	/**
	 *this new IllegalTemperatureTypeException with the given string as an error message for the user
	 *	
	 * @param 	message
	 * 			The text message of this new Illegal TemperatureType Exception that is to be returned
	 * @effect	The exception is invoked when the TemperatureType is invalid
	 */
	public IllegalTemperatureTypeException(String message)
	{
		this.message=message;
	}
	/**
	 * @return	returns the text message of this new Illegal TemperatureType Exception that
	 * 			is to be returned to the user
	 */
	public String getMessage()
	{
		return this.message;
	}
}
